<div class="tm-sidebar am-offcanvas am-margin-right" id="admin-offcanvas">
    <?php if ($login === false): ?>
        <ul class="am-list am-text-sm">
            <li class="am-padding-xs am-text-sm">
                <i class="am-icon-angellist"></i> 撑台面用
            </li>
            <li class="am-padding-sm">
                <ol class="am-margin-0 am-text-xs">
                    <li class="am-padding-bottom-sm">
                    <span>
                        您还没有登录:<br/>赶快登录瞧瞧本站内容。
                    </span>
                    </li>
                    <li class="am-padding-bottom-sm">
                    <span>
                        我主要作用：撑台面。
                    </span>
                    </li>
                </ol>
            </li>
        </ul>
    <?php else: ?>
        <ul class="am-list am-text-sm">
            <li class="am-padding-sm">
                <div class="am-margin-bottom-sm">
                    <img class="am-margin-right-xs am-img-thumbnail" src="<?= $_SESSION['user']['user_head']; ?>" alt="" width="48" height="48">
                    <span><?= $_SESSION['user']['user_name']; ?></span>
                </div>

            </li>
            <li class="am-padding-xs">
                <a href="<?= $label->url('Master-Article-user', ['id' => $_SESSION['user']['user_id']]); ?>" class="am-link-muted am-padding-0">
                    <i class="am-icon-bookmark"></i> 已发表 <?= $_SESSION['user']['user_timelog']; ?> 篇日志
                </a>
            </li>
            <li class="am-padding-xs">
                <a href="<?= $label->url('Master-Article-action'); ?>" class="am-link-muted am-padding-0">
                    <i class="am-icon-pencil"></i> 发表新的日志
                </a>
            </li>
            <li class="am-padding-xs">
                <a class="am-link-muted am-padding-0" href="/tips">
                    <span class="am-badge am-text-xs am-round"><?= $tipsNum; ?></span> 条未读消息
                </a>
            </li>
        </ul>
    <?php endif; ?>
    <?php if (!empty($currentType['type_description'])): ?>
        <ul class="am-list am-text-sm">
            <li class="am-padding-xs am-text-sm">
                <i class="am-icon-desktop"></i> <?= $currentType['type_name']; ?>
            </li>
            <li class="am-padding-sm">
                <?= htmlspecialchars_decode($currentType['type_description']); ?>
            </li>
        </ul>
    <?php endif; ?>
    <ul class="am-list am-text-sm">
        <li class="am-padding-xs am-text-sm">
            <i class="am-icon-trademark"></i> 广而告之
        </li>
        <?php if (DEBUG !== TRUE): ?>
            <li class="am-padding-xs am-text-sm">
                <script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
                <ins class="adsbygoogle"
                     style="display:block"
                     data-ad-client="ca-pub-9913541128177288"
                     data-ad-slot="2235649913"
                     data-ad-format="auto"></ins>
                <script>
                    (adsbygoogle = window.adsbygoogle || []).push({});
                </script>
            </li>
        <?php endif; ?>
    </ul>
</div>
